package com.cyzy.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.cyzy.pojo.Exhibition;
import com.cyzy.pojo.VoteRecord;
import com.cyzy.vo.CampusWorks;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface VoteMapper extends BaseMapper<Exhibition> {

//查询这个作品展的所有的作品Id,再查询对应的作品详情（图片链接，名字，作品，班级）
    List<CampusWorks> selectWorkDetailByExhId(@Param("exhId") Long exhId);

    //查询参与人数
    Long queryNumberParticipants(@Param("exhId") Long exhId);

    //查询投票总数
    Long queryTotalVote(@Param("exhId") Long exhId);

    //查询投票榜单
    Long queryVoteTop(@Param("exhId") Long exhId);

    //查询榜首信息
    String queryTopInfo(@Param("workId") Long workId);


}
